import useRequest from '../hook/request';

// 获取正在进行的服务项目 
export function getCustomerOnGoingServiceItemListApi(params: any, id:number) {
  return useRequest(
  `sick/accessLog/getCustomerOnGoingServiceItemList/${id}`,
    params,
    'GET'
  )
}

// 随访模板管理 列表
export function getPageApi(params: any) {
  return useRequest(
  `company/accessLog/model/getPage`,
    params,
    'POST'
  )
}
// 随访模版随访创建类型
export function getCreateTypeAPI(params: any) {
  return useRequest(
  `company/accessLog/model/getCreateType`,
    params,
    'GET'
  )
}

// 随访模版随访创建时间类型
export function getCreateTimeTypeAPI(params: any) {
  return useRequest(
  `company/accessLog/model/getCreateTimeType`,
    params,
    'GET'
  )
}

// 随访模版随访时间类型
export function getTimeTypeAPI(params: any) {
  return useRequest(
  `company/accessLog/model/getTimeType`,
    params,
    'GET'
  )
}


// 随访模版医生类型
export function getDoctorTypeAPI(params: any) {
  return useRequest(
  `company/accessLog/model/getDoctorType`,
    params,
    'GET'
  )
}

// 随访模版人员类型
export function getDealUserTypeAPI(params: any) {
  return useRequest(
  `company/accessLog/model/getDealUserType`,
    params,
    'GET'
  )
}



// 随访项目
export function getAccessFollowItemAPI(params: any) {
  return useRequest(
  `sick/accessLog/getAccessFollowItem`,
    params,
    'GET'
  )
}


// 随访内容下拉
export function getAccessFollowContentAPI(params: any) {
  return useRequest(
  `sick/accessLog/getAccessFollowContent`,
    params,
    'GET'
  )
}


// 随访模板添加
export function addModelAPi(params: any) {
  return useRequest(
    'company/accessLog/model/addModel',
    params,
    'POST'
  )
}

// 获取随访模板 单个数据
export function getModelDetailAPi(params: any, id: number) {
  return useRequest(
    `company/accessLog/model/getModelDetail/${id}`,
    params,
    'GET'
  )
}

// 随访模板 修改

export function updateModelAPi(params: any) {
  return useRequest(
    `company/accessLog/model/updateModel`,
    params,
    'POST'
  )
}

// 随访模板 删除
export function delModelAPi(params: any, id: number) {
  return useRequest(
    `company/accessLog/model/delModel/${id}`,
    params,
    'POST'
  )
}

// 随访模板状态切换
export function updateStatusAPi(params: any) {
  return useRequest(
    `company/accessLog/model/updateStatus`,
    params,
    'POST'
  )
}

// 随访模板 排序id
export function moveModelByIdsAPi(params: any) {
  return useRequest(
    `company/accessLog/model/moveModelByIds`,
    params,
    'POST'
  )
}

// 获取所有模版以及明细 
export function getAccessModelAndDetailAPi(params: any, id: number) {
  return useRequest(
    `sick/accessLog/getAccessModelAndDetail/${id}`,
    params,
    'GET'
  )
}

// 获取随访模版列表

export function getAccessModelAndDetailSelectAPi(params: any) {
  return useRequest(
    `sick/accessLog/getAccessModelAndDetailSelect`,
    params,
    'GET'
  )
}

// 新增随访 医生类型

export function getAccessDoctorSelectAPi(params: any, id:number) {
  return useRequest(
    `sick/accessLog/getAccessDoctorSelect/${id}`,
    params,
    'GET'
  )
}

// 新增随访 随访人员类型

export function getDealUserSelectAPi(params: any, id:number) {
  return useRequest(
    `sick/accessLog/getDealUserSelect/${id}`,
    params,
    'GET'
  )
}


// 新增随访 
export function createAccessPlanAPi(params: any) {
  return useRequest(
    `sick/accessLog/createAccessPlan`,
    params,
    'POST'
  )
}

